<template>
  <div class="layui-tab-content layui-body" id="LAY_app_body">
    <div class="layadmin-tabsbody-item layui-show">
      <iframe
        src="/manager/console"
        class="layadmin-iframe"
        frameborder="0"
      ></iframe>
    </div>
  </div>
</template>
<style>
@import "../../../../assets/css/manager/admin.css";
</style>
<script>
export default {
  name: "Body",
  methods: {
    loadBodys: function (t) {
      var href = $(t).attr("lay-href");
      var html =
        '<div class="layadmin-tabsbody-item" lay-id=' +
        href +
        '><iframe src="' +
        href +
        '" class="layadmin-iframe" frameborder="0"></iframe></div>';
      $("#LAY_app_body").append(html);
    },
    deleteBody: function (layid) {
      var bodys = $("#LAY_app_body").children();
      for (var i = 0; i < bodys.length; i++) {
        if ($(bodys[i]).attr("lay-id") == layid) {
          $(bodys[i]).remove();
        }
      }
    },
  },
};
</script>